/*
	File:		OptionState.h
	Course:		SGD 1301
	Author:		Peter Nguyen
	Purpose:	COptionState class handles the option screen
*/

#pragma once

#include "IGameState.h"


// Wrappers
class CSGD_DirectInput;
class CSGD_TextureManager;
class CSGD_XAudio2;
class CBitmapFont;



////////////////////////////////////////////////////////////
// CMainMenuState class
//	- game state to handle main menu
class COptionState : public IGameState
{
public:
	////////////////////////////////////////////////////////
	// SINGLETON!
	static COptionState* GetInstance( void );
	
	
	////////////////////////////////////////////////////////
	// IGameState Interface:
	virtual void	Enter	( void );			// load resources
	virtual void	Exit	( void );			// unload resources

	virtual bool	Input	( void );			// handle user input
	virtual void	Update	( float fElapsedTime );	// update game entities
	virtual void	Render	( void );			// render game entities
	

private:
	////////////////////////////////////////////////////////
	// Singleton - not dynamically allocated
	COptionState( void );
	virtual ~COptionState( void );
	COptionState( const COptionState& );
	COptionState& operator= ( const COptionState& );
	
	////////////////////////////////////////////////////////
	// Wrappers
	CSGD_DirectInput*		m_pDI;
	CSGD_TextureManager*	m_pTM;
	CSGD_XAudio2*			m_pXA;
	CBitmapFont*			m_pFont;
	
	////////////////////////////////////////////////////////
	// Image Asset
	int						m_nCursorImageID;
	
	////////////////////////////////////////////////////////
	// Audio Asset
	int						m_nBackgroundMusicID;
	int						m_nLaserShotSfxID;

	//Menu stuff
	int						m_nCursorPos;
	int						m_nMenuSize;

	
	void SaveSoundSettingToFile();
	void UnloadTextureHelper(int&id);
	void UnloadMusicHelper(int&id);
	void UnloadSFXHelper(int&id);

};

